import axios from "@/utils/http";
enum Api {
  url = "/v1/tasks",
}
export const Create = <T>(parmas: any) => {
  return axios.post<T>(Api.url, parmas) as T;
};
export const getList = <T>(parmas?: any) => {
  return axios.get<T>(Api.url, parmas) as T;
};
export const upDate = <T>(parmas: any) => {
  return axios.put<T>(`${Api.url}`, parmas) as T;
};
export const Delete = <T>(parmas: any) => {
  return axios.delete<T>(`${Api.url}/${parmas.uuid}`) as T;
};
export const Detail = <T>(parmas: any) => {
  return axios.get<T>(`${Api.url}/${parmas.uuid}`) as T;
};
